package com.agent.util;

import java.util.HashMap;
import java.util.Map;

/**
 * Created by hg on 2018/9/19.
 */
public class ResponseData {

    private static final String CODE="code";
    private static final String MSG="msg";
    private static final String SUCCESS_CODE="0";
    private static final String ERROR_CODE="1";
    private static final String SUCCESS_MSG="ok";
    public static final String COUNT="count";
    public static final String DATA="data";
    public static Map<String,Object> getSuccessResult(){
        Map<String,Object> result = new HashMap<String,Object>();
        result.put(CODE,SUCCESS_CODE);
        result.put(MSG,SUCCESS_MSG);
        return result;
    }

    public static Map<String,Object> getErrorResult(String errorMsg){
        Map<String,Object> result = new HashMap<String,Object>();
        result.put(CODE,ERROR_CODE);
        result.put(MSG,errorMsg);
        return result;
    }


}
